<?php use_javascripts_for_form($form) ?>
<?php use_stylesheet('orders.css') //load css pf order page   ?>
<?php use_stylesheet('forms.css') //load css pf order page   ?>
<?php use_stylesheet('hoverTables.css') //load css of tables  ?>
<!-- All forms that used newsucces or editsucces are in a div with the id form -->
<div id="form"> 
    <!-- the go back button on the side -->
    <a href="<?php echo url_for('sales/indexOrders') ?>" class="bt_back"><img src="<?php echo image_path('Buttons/bt_arrow_back.png') ?>" onmouseover="this.src='<?php echo image_path('Buttons/bt_arrow_back_hov.png') ?>'" onmouseout="this.src='<?php echo image_path('Buttons/bt_arrow_back.png') ?>'"></a>

    <?php 
    if($version == 'order'){ //normal order
        include_partial('orderNormal', array('form' => $form, 'products' => $products, 'parts' => $parts, 'status' => $status, 'category' => $category));
    }
    if($version == 'return') { //return order
        include_partial('orderReturn', array('form' => $form));    
    }
    if($version == 'stock') { //stock order
        include_partial('orderStock', array('form' => $form, 'products' => $products, 'status' => $status, 'category' => $category));    
    }
    ?>
</div><!-- close div form -->